Skip to content

[GDPVal] Allow partial_completion on the final stage - #3770

Merged
Kh4L merged 1 commit into
gdpval-develfrom
agronskiy/gdpval-final-stage-partial-completion
Sep 29, 2026
Merged

Kh4L merged 1 commit into
gdpval-develfrom
agronskiy/gdpval-final-stage-partial-completion

Conversation

@agronskiy

Copy link
Copy Markdown
Contributor

What

partial_completion was rejected on the final stage, and aggregation treated anything short of exactly N/N final-stage rows as final_stage_degraded=1. So the final stage had no coverage floor at all. Three super3.5@0.16.0 GDPVal-AA v2 runs landed at 215, 217 and 216 out of 220 and were marked cannot_certify.

This PR allows partial_completion on the final stage, using the same policy fields as the calibration stage:

  • Orchestrator: the final stage is evaluated against its policy. If the policy accepts the stage, the orchestrator records a partial_complete outcome and stamps accepted_stage_row_count on every row it keeps, in both the fresh path and the cached-resume path. If the policy rejects it, the stage behaves as before: it is scored and can finish, but is degraded.
  • app.py: adds comparison/final_stage_partial_accepted. The flag is 1 when every final-stage row carries the same accepted_stage_row_count and that count equals the observed row count. In that case final_stage_degraded=0 and the flat comparison/eval_elo / normalized_elo are emitted. final_stage_complete still means exactly N/N.
  • Without a final-stage policy, nothing changes.

Example (95% = 209/220):

++multistage.stages='[{num_tasks: 45, partial_completion: {...}}, {num_tasks: 220, num_models: 4, partial_completion: {min_success_fraction: 0.95, min_per_reference_success_fraction: 0.5, min_successful_rows_per_reference: 1}}]'

Refs #3341. This covers defect (b), the final stage's missing coverage floor. Defect (a), timeout_exceeded consuming the rollout attempt budget, is not addressed here.

Tests

  • pytest resources_servers/gdpval/tests/test_multistage_orchestrator.py: 140 passed. The two tests asserting that a final-stage policy is rejected are replaced with tests for acceptance and stamping, a cached-resume replay with no re-dispatch, and a below-floor run that stays unstamped.
  • pytest resources_servers/gdpval/tests/test_app.py: 100 passed. New parametrized cases cover an accepted count, a missing count, and a count that doesn't match the observed rows.
  • test_comparison_file_handling.py::test_oversize_xlsx_does_not_attempt_structured_extraction already fails on gdpval-devel before this change and is unrelated.
  • Not yet validated with a real rollout.

🤖 Generated with Claude Code

The final stage had no coverage floor: a run either reported exactly
N/N rows or was flagged final_stage_degraded, with nothing in between.
Three 0.16.0 runs landed 215-217/220 and were blocked from certification.

partial_completion may now be set on the final stage. When the policy
accepts it, the orchestrator stamps accepted_stage_row_count on the
kept rows, and aggregation reports final_stage_partial_accepted=1,
final_stage_degraded=0, and emits the flat headline. Below the floor
the stage is still scored but degraded, as before.
final_stage_complete stays exact.

Refs #3341

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Alex Gronskiy <agronskiy@nvidia.com>
@Kh4L
Kh4L merged commit 8231abf into gdpval-devel Sep 29, 2026
32 of 34 checks passed
@Kh4L
Kh4L deleted the agronskiy/gdpval-final-stage-partial-completion branch September 29, 2026 18:23
khazic pushed a commit to khazic/Gym-lao that referenced this pull request Oct 2, 2026
…o#3912)

## Summary

Ports NVIDIA-NeMo#3770 from `gdpval-devel` to main. NVIDIA-NeMo#3687 made `partial_completion`
unavailable on the final stage; this lets the final stage use it too.

- A final stage the policy accepts reports
`comparison/final_stage_partial_accepted: 1` and
`comparison/final_stage_degraded: 0`, and emits the flat
`comparison/eval_elo` / `comparison/normalized_elo`, even when the
observed row count is below the expected count.
`comparison/final_stage_complete` stays exact.
- A final stage below the floor is still scored, but reports
`final_stage_degraded: 1` and no flat headline.
- The accepted row count is recorded per row
(`accepted_stage_row_count`) and in the stage journal, so resume cannot
change which rows count.
- README documents the final-stage policy; the `partial_completion`
entry in the config table is updated to match.

Two files conflicted with main (the README `stages` row and a test
import); both are resolved to keep main's text plus the new behavior.

## Test plan

- `resources_servers/gdpval/tests` +
`tests/unit_tests/test_rollout_collection.py` +
`test_dispatch_latency.py`: 908 passed.
- `ruff check` and `ruff format --check` clean.

Signed-off-by: Serge Panev <spanev@nvidia.com>
Co-authored-by: Alexey Gronskiy <agronskiy@nvidia.com>

This branch was previously deployed

1 inactive deployment
public — 4f05a426 Deployed Sep 29, 2026 by copy-pr-bot[bot] via release / finalize / notify #3932
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants